package com.example.myui.activity;

import android.content.Context;
import android.support.annotation.Nullable;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.example.myui.R;
import com.example.myui.model.SchoolModel;

import java.util.List;

/**
 * Created by Administrator on 2018/1/8/008.
 */

public class MyAdapter extends BaseQuickAdapter<SchoolModel, BaseViewHolder> {
    private Context mContext;

    public MyAdapter(Context context, @Nullable List<SchoolModel> data) {
        super(R.layout.item_type_name, data);
        this.mContext = context;
    }

    @Override
    protected void convert(BaseViewHolder holder, SchoolModel item) {
        holder.setText(R.id.tv_name, item.getName());
        holder.setText(R.id.tv_time, item.getTime());
    }
}
